package com.zjhn.ds.param;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;

/**
 * @BelongsProject: ds_jlw
 * @BelongsPackage: com.zjhn.ds.param
 * @Author: sxt
 * @CreateTime: 2023-09-14  18:20
 * @Description:
 * @Version: 1.0
 */
@Data
public class AddUpdateStationParam {

    @ApiModelProperty("工位id")
    @JsonProperty("station_id")
    private String stationId;

    @ApiModelProperty("车间id")
    @JsonProperty("workshop_id")
    @NotBlank(message = "车间id不能为空")
    private String workshopId;

    @ApiModelProperty("工位编码")
    @JsonProperty("station_code")
    @NotBlank(message = "机台编码不能为空")
    @Pattern(regexp = "^(\\d{1,})-(\\d{1,})-(\\d{1,})$", message = "机台编码格式错误")
    private String stationCode;

    @ApiModelProperty("工位名称")
    @JsonProperty("station_name")
    @Pattern(regexp="^[\\d]{1,}$",message = "工位名称为数字类别的字符串")
    private String stationName;

    @ApiModelProperty("设备id")
    @JsonProperty("equipment_id")
    private String equipmentId;

}

